package com.chuangjiangx.member.stored.service.model;

import lombok.Builder;
import lombok.Data;
import org.hibernate.validator.constraints.NotBlank;

import javax.validation.constraints.*;
import java.math.BigDecimal;

/**
 * @author cj-ch
 * @date 2018/9/11 下午7:16
 * 第三方C扫B统一下单
 */
@Data
@Builder
public class CtoBThirdPartyPayRequest {

    /**
     * 第三方订单编号
     */
    @NotBlank
    @Size(min = 1,max = 45)
    private String outTradeNo;

    @NotNull
    @Min(value = 1)
    private Long merchantId;
    /**
     * 商户用户Id
     */
    @NotNull
    @Min(value = 1)
    private Long merchantUserId;

    @NotNull
    @Min(value = 0)
    private Integer payTerminal;
    /**
     * 订单金额
     */
    @DecimalMin(value = "0.01")
    private BigDecimal amount;

    /**
     * 商品名称
     */
    private String goodName;
    /**
     * 自定义属性
     */
    private String attach;
    /**
     * 回调地址
     */
    @NotBlank
    @Size(min = 5,max = 256)
    private String callBackUrl;
    private String note;

    /**
     * @see com.chuangjiangx.domain.shared.model.PayEntry
     */
    @NotNull
    @Min(value = -1)
    @Max(value = 7)
    private Integer payEntry;

    /**
     * 微信支付参数
     */
    private WxMicroPayRequest wx;

//    private AliMicroPayCommand ali;



}
